package router

import (
	"github.com/gin-gonic/gin"
	"mxshop_api/goods-web/api/category"
)

func InitCategoryRouter(router *gin.RouterGroup) {

	router.GET("", category.List)          // 商品类别列表页
	router.DELETE("/:id", category.Delete) // 删除分类
	router.GET("/:id", category.Detail)    // 获取分类详情
	router.POST("", category.New)          //新建分类
	router.PUT("/:id", category.Update)    //修改分类信息
}
